package com.xtianzhuang.www.study2019.practice.niuke;

public class Practice2 {
	private String baseName = "base";

	public Practice2() {
		callName();
	}

	public void callName() {
		System.out.println(baseName);
	}

	static class Sub extends Practice2 {
		private String baseName = "sub";

		@Override
		public void callName() {
			System.out.println(baseName);
		}
	}

	public static void main(String[] args) {
		Practice2 b = new Sub();
	}

}

